package com.yundasys.lab15springbootes.lab15springbootes.model;

import cn.easyes.annotation.IndexName;
import cn.easyes.common.constants.Analyzer;
import cn.easyes.common.enums.FieldType;
import lombok.Data;
import lombok.ToString;

/**
 * @PACKAGE_NAME: com.yundasys.lab15springbootes.lab15springbootes.model
 * @NAME: Document
 * @USER: jiangta
 * @DATE: 2022/9/16
 * @TIME: 8:01 下午
 * @PROJECT_NAME: springboot-labs
 */
@Data
@IndexName(shardsNum = 5, replicasNum = 1,value = "document")
@ToString
public class Document {
    /**
     * es中的唯一id
     */
    private String id;

    /**
     * 文档标题
     */
    private String title;
    /**
     * 文档内容 (如需分词查询,可将下面注释的注解内容开启)
     */
    //@TableField(fieldType= FieldType.TEXT,analyzer= Analyzer.IK_SMART,searchAnalyzer=Analyzer.IK_SMART)
    private String content;
}
